/*
 *    Copyright (c) 2018-2025, lengleng All rights reserved.
 *
 * Redistribution and use in source and binary forms, with or without
 * modification, are permitted provided that the following conditions are met:
 *
 * Redistributions of source code must retain the above copyright notice,
 * this list of conditions and the following disclaimer.
 * Redistributions in binary form must reproduce the above copyright
 * notice, this list of conditions and the following disclaimer in the
 * documentation and/or other materials provided with the distribution.
 * Neither the name of the pig4cloud.com developer nor the names of its
 * contributors may be used to endorse or promote products derived from
 * this software without specific prior written permission.
 * Author: lengleng (wangiegie@gmail.com)
 */

package com.pig4cloud.pigx.shop.user.api.entity;

import com.baomidou.mybatisplus.annotation.*;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import lombok.EqualsAndHashCode;
import java.io.Serializable;
import java.time.LocalDateTime;

/**
 * 用户积分变更记录
 *
 * @author pigx code generator
 * @date 2023-12-23 09:11:16
 */
@Data
@TableName("shop_user_point_change_record")
@EqualsAndHashCode(callSuper = true)
@Schema(description = "用户积分变更记录")
public class ShopUserPointChangeRecord extends Model<ShopUserPointChangeRecord> {

	private static final long serialVersionUID = 1L;

	/**
	 * id
	 */
	@TableId(type = IdType.ASSIGN_ID)
	@Schema(description = "id")
	private Long id;

	/**
	 * 名称
	 */
	@Schema(description = "名称")
	private String recordName;

	/**
	 * 关联图片
	 */
	@Schema(description = "关联图片")
	private String recordImages;

	/**
	 * 类型 1: 商品商城 2: 优惠券 3: 平台操作 4: 权益包 5: 积分商城
	 */
	@Schema(description = "类型 1: 商品商城 2: 优惠券 3: 平台操作 4: 权益包 5: 积分商城")
	private String recordType;

	/**
	 * 用户ID
	 */
	@Schema(description = "用户ID")
	private Long shopUserId;

	/**
	 * 关联订单ID
	 */
	@Schema(description = "关联订单ID")
	private Long recordOrderId;

	/**
	 * 状态 1: 处理中 2: 成功 3: 失败
	 */
	@Schema(description = "状态 1: 处理中 2: 成功 3: 失败")
	private String status;

	/**
	 * 状态 1: 处理中 2: 成功 3: 失败
	 */
	@Schema(description = "状态 1: 处理中 2: 成功 3: 失败")
	private String oper;

	/**
	 * 积分
	 */
	@Schema(description = "积分")
	private Integer point;

	/**
	 * 失败理由
	 */
	@Schema(description = "失败理由")
	private String failReason;

	/**
	 * 备注
	 */
	@Schema(description = "备注")
	private String remark;

	/**
	 * 删除标记
	 */
	@TableLogic
	@Schema(description = "删除标记")
	private String delFlag;

	/**
	 * 创建人
	 */
	@TableField(fill = FieldFill.INSERT)
	@Schema(description = "创建人")
	private String createBy;

	/**
	 * 修改人
	 */
	@TableField(fill = FieldFill.UPDATE)
	@Schema(description = "修改人")
	private String updateBy;

	/**
	 * 创建时间
	 */
	@Schema(description = "创建时间")
	@TableField(fill = FieldFill.INSERT)
	private LocalDateTime createTime;

	/**
	 * 修改时间
	 */
	@Schema(description = "修改时间")
	@TableField(fill = FieldFill.UPDATE)
	private LocalDateTime updateTime;

}
